<?php
class A
{
	public function m($args)
	{
		call_user_func_array('cb', $args);
	}
	
	public function n(&$m)
	{
		$this->m(array($this, &$m));
		echo $m;
	}
}

function cb(&$a1, &$a2)
{
	$a1->a = 2;
	$a2 = 2;
}

$m = 1;
$a = new A;
$a->n($m);

echo $a->a;